<?php
declare (strict_types = 1);

namespace app\admin\controller;

use think\Exception;
use think\facade\Log;
use think\facade\View;

class ProductSpec extends Base{

    public function dialog() : string {

        $specs = [];

        try{
            $specs = (new \app\business\ProductSpec())->getList();
        }catch (Exception $e){
            Log::error($e->getMessage());
        }

        return View::fetch("", [
            "specs" => json_encode($specs)
        ]);
    }
}